export type HttpMethod = 'GET' | 'POST' | 'PUT' | 'DELETE';

export interface HttpConfig {
  host: string;
  api: string;
  method: HttpMethod;
  params: Record<string, string>;
  headers: Record<string, string>;
  body: unknown;
}

// 表单内部把对象转成 [k,v][]
export interface FormHttpConfig
  extends Omit<HttpConfig, 'params' | 'headers' | 'body'> {
  params: [string, string][];
  headers: [string, string][];
  body: string;
}
